<template name="newAdminAppSources">
{{#let txt="admin.appSources.newAdminAppSources"}}
  <h1>
    <ul class="admin-breadcrumbs">
      <li>{{#linkTo route="newAdminRoot"}}{{_ "admin.title"}}{{/linkTo}}</li>
      <li>{{_ "admin.appSources.name"}}</li>
    </ul>
  </h1>

  {{#if hasSuccess}}
    {{#focusingSuccessBox}}
      {{message}}
    {{/focusingSuccessBox}}
  {{/if}}
  {{#if hasError}}
    {{#focusingErrorBox}}
      {{message}}
    {{/focusingErrorBox}}
  {{/if}}
  <form class="admin-app-sources">
    <div class="form-group">
      <label>
        {{_ (con txt "appMarketUrl.label")}}
        <input type="text" name="appMarketUrl" value="{{appMarketUrl}}" />
      </label>
      <span class="form-subtext">
        {{_ (con txt "appMarketUrl.subtext")}}
      </span>
    </div>

    <div class="form-group">
      <label>
        <input type="checkbox" name="enableAppUpdates" checked="{{enableAppUpdates}}" />
        {{_ (con txt "enableAppUpdates.label")}}
      </label>
      <span class="form-subtext">
        {{_ (con txt "enableAppUpdates.subtext")}}
      </span>
    </div>

    {{#if enableAppUpdates}}
    <div class="form-group">
      <label>
        {{_ (con txt "appIndexUrl.label")}}
        <input type="text" name="appIndexUrl" value="{{appIndexUrl}}" />
      </label>
      <span class="form-subtext">
        {{_ (con txt "appIndexUrl.subtext")}}
      </span>
    </div>
    {{/if}}

    <div class="button-row">
      <button type="submit" class="save" disabled="{{saveDisabled}}">{{_ (con txt "saveButton")}}</button>
      <button type="button" class="restore" disabled="{{restoreDisabled}}">{{_ (con txt "restoreButton")}}</button>
    </div>
  </form>
{{/let}}
</template>
